package date1127.ref;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import com.lu.jdog.util.Resource;

public class SpringTest {
private static ApplicationContext applicationContext;

public static void main(String[] args) {
	String xml1 = Resource.getAssertPath(SpringTest.class,"beans1.xml");
	String xml2 = Resource.getAssertPath(SpringTest.class,"beans2.xml");
	
	applicationContext = new ClassPathXmlApplicationContext(new String[]{xml1,xml2});
	
	Trumpet trumpet1 = (Trumpet) applicationContext.getBean("trumpet1");
	trumpet1.play();
	
	Trumpet trumpet2 = (Trumpet) applicationContext.getBean("trumpet2");
	trumpet2.play();
	
	
	
}
}
